var express = require('express');
var router = express.Router();
let user = require("../controller/users");

/* GET users listing. */
router.get('/', function(req, res, next) {
  res.send('respond with a resource');
});

router.post('/register',user.register);

router.post('/login',user.login);

router.get('/findbyid/:user_id',user.findbyid);

router.get('/find/:username',user.find);

router.put('/update',user.update);

router.put("/avatar",user.avatar);

module.exports = router;
